<!-- HTML header for doxygen 1.8.3.1-->
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.8.3.1"/>
<title>Sifteo SDK: filesystem.h Source File</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/search.js"></script>
<script type="text/javascript">
  $(document).ready(function() { searchBox.OnSelectItem(0); });
</script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
<link href="doxygen-style-overrides.css" rel="stylesheet" type="text/css"/>
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<center>
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td id="projectlogo"><img alt="Sifteo SDK" src="sdk_logo.png"/></td>
  <td style="padding-left: 0.5em;">
   <div id="projectname">
   &#160;<span id="projectnumber">v1.0.0</span>
   </div>
  </td>
 </tr>
 </tbody>
</table>
</div>
</center>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.3.1 -->
<script type="text/javascript">
var searchBox = new SearchBox("searchBox", "search",false,'Search');
</script>
  <div id="navrow1" class="tabs">
    <ul class="tablist">
      <li><a href="index.html"><span>Home</span></a></li>
      <li><a href="pages.html"><span>Guides</span></a></li>
      <li><a href="modules.html"><span>Modules</span></a></li>
      <li><a href="annotated.html"><span>Reference</span></a></li>
      <li>
        <div id="MSearchBox" class="MSearchBoxInactive">
        <span class="left">
          <img id="MSearchSelect" src="search/mag_sel.png"
               onmouseover="return searchBox.OnSearchSelectShow()"
               onmouseout="return searchBox.OnSearchSelectHide()"
               alt=""/>
          <input type="text" id="MSearchField" value="Search" accesskey="S"
               onfocus="searchBox.OnSearchFieldFocus(true)" 
               onblur="searchBox.OnSearchFieldFocus(false)" 
               onkeyup="searchBox.OnSearchFieldChange(event)"/>
          </span><span class="right">
            <a id="MSearchClose" href="javascript:searchBox.CloseResultsWindow()"><img id="MSearchCloseImg" border="0" src="search/close.png" alt=""/></a>
          </span>
        </div>
      </li>
    </ul>
  </div>
  <div id="navrow2" class="tabs2">
    <ul class="tablist">
      <li><a href="files.html"><span>File&#160;List</span></a></li>
    </ul>
  </div>
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
<a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(0)"><span class="SelectionMark">&#160;</span>All</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(1)"><span class="SelectionMark">&#160;</span>Classes</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(2)"><span class="SelectionMark">&#160;</span>Namespaces</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(3)"><span class="SelectionMark">&#160;</span>Functions</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(4)"><span class="SelectionMark">&#160;</span>Variables</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(5)"><span class="SelectionMark">&#160;</span>Typedefs</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(6)"><span class="SelectionMark">&#160;</span>Enumerations</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(7)"><span class="SelectionMark">&#160;</span>Enumerator</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(8)"><span class="SelectionMark">&#160;</span>Groups</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(9)"><span class="SelectionMark">&#160;</span>Pages</a></div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0" 
        name="MSearchResults" id="MSearchResults">
</iframe>
</div>

<div id="nav-path" class="navpath">
  <ul>
<li class="navelem"><a class="el" href="dir_12cda917fe1d7c8b4e7d2501bb3636e4.html">sdk</a></li><li class="navelem"><a class="el" href="dir_2f23e30b638d6a5f333babd9a5d183e1.html">include</a></li><li class="navelem"><a class="el" href="dir_d5ace589187da7c83c1a7507ec9fbbef.html">sifteo</a></li>  </ul>
</div>
</div><!-- top -->
<div class="header">
  <div class="headertitle">
<div class="title">filesystem.h</div>  </div>
</div><!--header-->
<div class="contents">
<div class="fragment"><div class="line"><a name="l00001"></a><span class="lineno">    1</span>&#160;<span class="comment">/*</span></div>
<div class="line"><a name="l00002"></a><span class="lineno">    2</span>&#160;<span class="comment"> * This file is part of the public interface to the Sifteo SDK.</span></div>
<div class="line"><a name="l00003"></a><span class="lineno">    3</span>&#160;<span class="comment"> * Copyright &lt;c&gt; 2012 Sifteo, Inc. All rights reserved.</span></div>
<div class="line"><a name="l00004"></a><span class="lineno">    4</span>&#160;<span class="comment"> */</span></div>
<div class="line"><a name="l00005"></a><span class="lineno">    5</span>&#160;</div>
<div class="line"><a name="l00006"></a><span class="lineno">    6</span>&#160;<span class="preprocessor">#pragma once</span></div>
<div class="line"><a name="l00007"></a><span class="lineno">    7</span>&#160;<span class="preprocessor"></span><span class="preprocessor">#ifdef NOT_USERSPACE</span></div>
<div class="line"><a name="l00008"></a><span class="lineno">    8</span>&#160;<span class="preprocessor"></span><span class="preprocessor">#   error This is a userspace-only header, not allowed by the current build.</span></div>
<div class="line"><a name="l00009"></a><span class="lineno">    9</span>&#160;<span class="preprocessor"></span><span class="preprocessor">#endif</span></div>
<div class="line"><a name="l00010"></a><span class="lineno">   10</span>&#160;<span class="preprocessor"></span></div>
<div class="line"><a name="l00011"></a><span class="lineno">   11</span>&#160;<span class="preprocessor">#include &lt;sifteo/array.h&gt;</span></div>
<div class="line"><a name="l00012"></a><span class="lineno">   12</span>&#160;<span class="preprocessor">#include &lt;sifteo/asset/loader.h&gt;</span></div>
<div class="line"><a name="l00013"></a><span class="lineno">   13</span>&#160;<span class="preprocessor">#include &lt;sifteo/abi.h&gt;</span></div>
<div class="line"><a name="l00014"></a><span class="lineno">   14</span>&#160;</div>
<div class="line"><a name="l00015"></a><span class="lineno">   15</span>&#160;<span class="keyword">namespace </span>Sifteo {</div>
<div class="line"><a name="l00016"></a><span class="lineno">   16</span>&#160;</div>
<div class="line"><a name="l00055"></a><span class="lineno"><a class="code" href="class_sifteo_1_1_stored_object.html">   55</a></span>&#160;<span class="keyword">class </span><a class="code" href="class_sifteo_1_1_stored_object.html" title="A lightweight ID for a persistently stored object.">StoredObject</a> {</div>
<div class="line"><a name="l00056"></a><span class="lineno">   56</span>&#160;<span class="keyword">public</span>:</div>
<div class="line"><a name="l00057"></a><span class="lineno">   57</span>&#160;    _SYSObjectKey sys;</div>
<div class="line"><a name="l00058"></a><span class="lineno">   58</span>&#160;</div>
<div class="line"><a name="l00060"></a><span class="lineno"><a class="code" href="class_sifteo_1_1_stored_object.html#abc14a56c915a952bd644e0cea23aad0b">   60</a></span>&#160;    <span class="keyword">static</span> <span class="keyword">const</span> <span class="keywordtype">unsigned</span> <a class="code" href="class_sifteo_1_1_stored_object.html#abc14a56c915a952bd644e0cea23aad0b" title="Maximum allowed value for a key (255)">LIMIT</a> = _SYS_FS_MAX_OBJECT_KEYS - 1;</div>
<div class="line"><a name="l00061"></a><span class="lineno">   61</span>&#160;</div>
<div class="line"><a name="l00063"></a><span class="lineno"><a class="code" href="class_sifteo_1_1_stored_object.html#a91a58f0e70aed3ff2adc112d8f072e01">   63</a></span>&#160;    <span class="keyword">static</span> <span class="keyword">const</span> <span class="keywordtype">unsigned</span> <a class="code" href="class_sifteo_1_1_stored_object.html#a91a58f0e70aed3ff2adc112d8f072e01" title="Maximum size of an object, in bytes (4080)">MAX_SIZE</a> = _SYS_FS_MAX_OBJECT_SIZE;</div>
<div class="line"><a name="l00064"></a><span class="lineno">   64</span>&#160;</div>
<div class="line"><a name="l00066"></a><span class="lineno"><a class="code" href="class_sifteo_1_1_stored_object.html#a52e0318a54610cf4a302bf80325ad077">   66</a></span>&#160;    <a class="code" href="class_sifteo_1_1_stored_object.html#a52e0318a54610cf4a302bf80325ad077" title="Initialize from a system object.">StoredObject</a>(_SYSObjectKey k) : sys(k) {}</div>
<div class="line"><a name="l00067"></a><span class="lineno">   67</span>&#160;</div>
<div class="line"><a name="l00069"></a><span class="lineno"><a class="code" href="class_sifteo_1_1_stored_object.html#a6beec358463c3f08eeea605966f95c08">   69</a></span>&#160;    <a class="code" href="class_sifteo_1_1_stored_object.html#a6beec358463c3f08eeea605966f95c08" title="Initialize from an integer.">StoredObject</a>(<span class="keywordtype">int</span> k) : sys(k) {</div>
<div class="line"><a name="l00070"></a><span class="lineno">   70</span>&#160;        <a class="code" href="group__macros.html#ga8a15779356736a0900a162442b1cda53" title="Runtime debug assertion.">ASSERT</a>(k &gt;= 0 &amp;&amp; k &lt;= <a class="code" href="class_sifteo_1_1_stored_object.html#abc14a56c915a952bd644e0cea23aad0b" title="Maximum allowed value for a key (255)">LIMIT</a>);</div>
<div class="line"><a name="l00071"></a><span class="lineno">   71</span>&#160;    }</div>
<div class="line"><a name="l00072"></a><span class="lineno">   72</span>&#160;</div>
<div class="line"><a name="l00074"></a><span class="lineno"><a class="code" href="class_sifteo_1_1_stored_object.html#af5b59dc737e0a63b4a5234c795f3b9e3">   74</a></span>&#160;    <a class="code" href="class_sifteo_1_1_stored_object.html#af5b59dc737e0a63b4a5234c795f3b9e3" title="Initialize from an unsigned integer.">StoredObject</a>(<span class="keywordtype">unsigned</span> k) : sys(k) {</div>
<div class="line"><a name="l00075"></a><span class="lineno">   75</span>&#160;        <a class="code" href="group__macros.html#ga8a15779356736a0900a162442b1cda53" title="Runtime debug assertion.">ASSERT</a>(k &lt;= <a class="code" href="class_sifteo_1_1_stored_object.html#abc14a56c915a952bd644e0cea23aad0b" title="Maximum allowed value for a key (255)">LIMIT</a>);</div>
<div class="line"><a name="l00076"></a><span class="lineno">   76</span>&#160;    }</div>
<div class="line"><a name="l00077"></a><span class="lineno">   77</span>&#160;</div>
<div class="line"><a name="l00079"></a><span class="lineno"><a class="code" href="class_sifteo_1_1_stored_object.html#a0ebfedbbbd04d075d0a36bf1b4781e22">   79</a></span>&#160;    <span class="keyword">operator</span> <span class="keyword">const</span> _SYSObjectKey ()<span class="keyword"> const </span>{ <span class="keywordflow">return</span> sys; }</div>
<div class="line"><a name="l00080"></a><span class="lineno">   80</span>&#160;</div>
<div class="line"><a name="l00092"></a><span class="lineno"><a class="code" href="class_sifteo_1_1_stored_object.html#a59d04839bec8308a678d360de5eceeca">   92</a></span>&#160;    <span class="keyword">static</span> <a class="code" href="class_sifteo_1_1_stored_object.html" title="A lightweight ID for a persistently stored object.">StoredObject</a> <a class="code" href="class_sifteo_1_1_stored_object.html#a59d04839bec8308a678d360de5eceeca" title="Allocate a unique StoredObject value at compile-time.">allocate</a>() {</div>
<div class="line"><a name="l00093"></a><span class="lineno">   93</span>&#160;        <span class="keywordflow">return</span> <a class="code" href="class_sifteo_1_1_stored_object.html#a52e0318a54610cf4a302bf80325ad077" title="Initialize from a system object.">StoredObject</a>(<a class="code" href="class_sifteo_1_1_stored_object.html#abc14a56c915a952bd644e0cea23aad0b" title="Maximum allowed value for a key (255)">LIMIT</a> - _SYS_lti_counter(<span class="stringliteral">&quot;Sifteo.StoredObject&quot;</span>, 0));</div>
<div class="line"><a name="l00094"></a><span class="lineno">   94</span>&#160;    }</div>
<div class="line"><a name="l00095"></a><span class="lineno">   95</span>&#160;</div>
<div class="line"><a name="l00119"></a><span class="lineno"><a class="code" href="class_sifteo_1_1_stored_object.html#a753f6a27739f8dcf5aa2c898979e637d">  119</a></span>&#160;    <span class="keywordtype">int</span> <a class="code" href="class_sifteo_1_1_stored_object.html#a753f6a27739f8dcf5aa2c898979e637d" title="Read a stored object into memory.">read</a>(<span class="keywordtype">void</span> *buffer, <span class="keywordtype">unsigned</span> bufferSize, _SYSVolumeHandle volume = 0)<span class="keyword"> const </span>{</div>
<div class="line"><a name="l00120"></a><span class="lineno">  120</span>&#160;        <span class="keywordflow">return</span> _SYS_fs_objectRead(sys, (uint8_t*)buffer, bufferSize, volume);</div>
<div class="line"><a name="l00121"></a><span class="lineno">  121</span>&#160;    }</div>
<div class="line"><a name="l00122"></a><span class="lineno">  122</span>&#160;</div>
<div class="line"><a name="l00140"></a><span class="lineno"><a class="code" href="class_sifteo_1_1_stored_object.html#a041e820e61e67ca90bc8ee225b6060bb">  140</a></span>&#160;    <span class="keywordtype">int</span> <a class="code" href="class_sifteo_1_1_stored_object.html#a041e820e61e67ca90bc8ee225b6060bb" title="Save a new version of an object.">write</a>(<span class="keyword">const</span> <span class="keywordtype">void</span> *data, <span class="keywordtype">unsigned</span> dataSize)<span class="keyword"> const </span>{</div>
<div class="line"><a name="l00141"></a><span class="lineno">  141</span>&#160;        <span class="keywordflow">return</span> _SYS_fs_objectWrite(sys, (<span class="keyword">const</span> uint8_t*)data, dataSize);</div>
<div class="line"><a name="l00142"></a><span class="lineno">  142</span>&#160;    }</div>
<div class="line"><a name="l00143"></a><span class="lineno">  143</span>&#160;</div>
<div class="line"><a name="l00145"></a><span class="lineno"><a class="code" href="class_sifteo_1_1_stored_object.html#ab156f27919a9ffe4502af21322a4b2bc">  145</a></span>&#160;    <span class="keywordtype">int</span> <a class="code" href="class_sifteo_1_1_stored_object.html#ab156f27919a9ffe4502af21322a4b2bc" title="Erase this object. Equivalent to a zero-length write()">erase</a>()<span class="keyword"> const </span>{</div>
<div class="line"><a name="l00146"></a><span class="lineno">  146</span>&#160;        <span class="keywordflow">return</span> <a class="code" href="class_sifteo_1_1_stored_object.html#a041e820e61e67ca90bc8ee225b6060bb" title="Save a new version of an object.">write</a>(0, 0);</div>
<div class="line"><a name="l00147"></a><span class="lineno">  147</span>&#160;    }</div>
<div class="line"><a name="l00148"></a><span class="lineno">  148</span>&#160;</div>
<div class="line"><a name="l00155"></a><span class="lineno">  155</span>&#160;    <span class="keyword">template</span> &lt;<span class="keyword">typename</span> T&gt;</div>
<div class="line"><a name="l00156"></a><span class="lineno"><a class="code" href="class_sifteo_1_1_stored_object.html#a66b6325773616d8442172db7bbfa6b7d">  156</a></span>&#160;    <span class="keywordtype">int</span> <a class="code" href="class_sifteo_1_1_stored_object.html#a66b6325773616d8442172db7bbfa6b7d" title="Template wrapper for read() of fixed-size objects.">read</a>(T &amp;buffer, _SYSVolumeHandle volume = 0)<span class="keyword"> const </span>{</div>
<div class="line"><a name="l00157"></a><span class="lineno">  157</span>&#160;        <span class="keywordflow">return</span> <a class="code" href="class_sifteo_1_1_stored_object.html#a753f6a27739f8dcf5aa2c898979e637d" title="Read a stored object into memory.">read</a>((<span class="keywordtype">void</span>*) &amp;buffer, <span class="keyword">sizeof</span> buffer, volume);</div>
<div class="line"><a name="l00158"></a><span class="lineno">  158</span>&#160;    }</div>
<div class="line"><a name="l00159"></a><span class="lineno">  159</span>&#160;</div>
<div class="line"><a name="l00161"></a><span class="lineno">  161</span>&#160;    <span class="keyword">template</span> &lt;<span class="keyword">typename</span> T&gt;</div>
<div class="line"><a name="l00162"></a><span class="lineno"><a class="code" href="class_sifteo_1_1_stored_object.html#a764859c5bdc13a30acd5733f355a340c">  162</a></span>&#160;    <span class="keywordtype">int</span> <a class="code" href="class_sifteo_1_1_stored_object.html#a764859c5bdc13a30acd5733f355a340c" title="Template wrapper for read() of fixed-size objects.">readObject</a>(T &amp;buffer, _SYSVolumeHandle volume = 0)<span class="keyword"> const </span>{</div>
<div class="line"><a name="l00163"></a><span class="lineno">  163</span>&#160;        <span class="keywordflow">return</span> <a class="code" href="class_sifteo_1_1_stored_object.html#a753f6a27739f8dcf5aa2c898979e637d" title="Read a stored object into memory.">read</a>((<span class="keywordtype">void</span>*) &amp;buffer, <span class="keyword">sizeof</span> buffer, volume);</div>
<div class="line"><a name="l00164"></a><span class="lineno">  164</span>&#160;    }</div>
<div class="line"><a name="l00165"></a><span class="lineno">  165</span>&#160;</div>
<div class="line"><a name="l00172"></a><span class="lineno">  172</span>&#160;    <span class="keyword">template</span> &lt;<span class="keyword">typename</span> T&gt;</div>
<div class="line"><a name="l00173"></a><span class="lineno"><a class="code" href="class_sifteo_1_1_stored_object.html#a772401b125e4898f920ee8e76aa5e6cd">  173</a></span>&#160;    <span class="keywordtype">int</span> <a class="code" href="class_sifteo_1_1_stored_object.html#a772401b125e4898f920ee8e76aa5e6cd" title="Template wrapper for write() of fixed-size objects.">write</a>(<span class="keyword">const</span> T &amp;buffer)<span class="keyword"> const </span>{</div>
<div class="line"><a name="l00174"></a><span class="lineno">  174</span>&#160;        <span class="keywordflow">return</span> <a class="code" href="class_sifteo_1_1_stored_object.html#a041e820e61e67ca90bc8ee225b6060bb" title="Save a new version of an object.">write</a>((<span class="keyword">const</span> <span class="keywordtype">void</span>*) &amp;buffer, <span class="keyword">sizeof</span> buffer);</div>
<div class="line"><a name="l00175"></a><span class="lineno">  175</span>&#160;    }</div>
<div class="line"><a name="l00176"></a><span class="lineno">  176</span>&#160;</div>
<div class="line"><a name="l00178"></a><span class="lineno">  178</span>&#160;    <span class="keyword">template</span> &lt;<span class="keyword">typename</span> T&gt;</div>
<div class="line"><a name="l00179"></a><span class="lineno"><a class="code" href="class_sifteo_1_1_stored_object.html#a42b814d79fdd03a479dc0ff4b0d47dba">  179</a></span>&#160;    <span class="keywordtype">int</span> <a class="code" href="class_sifteo_1_1_stored_object.html#a42b814d79fdd03a479dc0ff4b0d47dba" title="Template wrapper for write() of fixed-size objects.">writeObject</a>(<span class="keyword">const</span> T &amp;buffer)<span class="keyword"> const </span>{</div>
<div class="line"><a name="l00180"></a><span class="lineno">  180</span>&#160;        <span class="keywordflow">return</span> <a class="code" href="class_sifteo_1_1_stored_object.html#a041e820e61e67ca90bc8ee225b6060bb" title="Save a new version of an object.">write</a>((<span class="keyword">const</span> <span class="keywordtype">void</span>*) &amp;buffer, <span class="keyword">sizeof</span> buffer);</div>
<div class="line"><a name="l00181"></a><span class="lineno">  181</span>&#160;    }</div>
<div class="line"><a name="l00182"></a><span class="lineno">  182</span>&#160;</div>
<div class="line"><a name="l00184"></a><span class="lineno"><a class="code" href="class_sifteo_1_1_stored_object.html#a6c7debc516198f7d0e00aabd5359512d">  184</a></span>&#160;    <span class="keywordtype">bool</span> <a class="code" href="class_sifteo_1_1_stored_object.html#a6c7debc516198f7d0e00aabd5359512d" title="Equality comparison operator.">operator== </a>(_SYSObjectKey other)<span class="keyword"> const </span>{</div>
<div class="line"><a name="l00185"></a><span class="lineno">  185</span>&#160;        <span class="keywordflow">return</span> sys == other;</div>
<div class="line"><a name="l00186"></a><span class="lineno">  186</span>&#160;    }</div>
<div class="line"><a name="l00187"></a><span class="lineno">  187</span>&#160;</div>
<div class="line"><a name="l00189"></a><span class="lineno"><a class="code" href="class_sifteo_1_1_stored_object.html#a97e6a3a014eaf846596222693162ea0f">  189</a></span>&#160;    <span class="keywordtype">bool</span> <a class="code" href="class_sifteo_1_1_stored_object.html#a97e6a3a014eaf846596222693162ea0f" title="Inequality comparison operator.">operator!= </a>(_SYSObjectKey other)<span class="keyword"> const </span>{</div>
<div class="line"><a name="l00190"></a><span class="lineno">  190</span>&#160;        <span class="keywordflow">return</span> sys != other;</div>
<div class="line"><a name="l00191"></a><span class="lineno">  191</span>&#160;    }</div>
<div class="line"><a name="l00192"></a><span class="lineno">  192</span>&#160;};</div>
<div class="line"><a name="l00193"></a><span class="lineno">  193</span>&#160;</div>
<div class="line"><a name="l00194"></a><span class="lineno">  194</span>&#160;</div>
<div class="line"><a name="l00206"></a><span class="lineno"><a class="code" href="class_sifteo_1_1_volume.html">  206</a></span>&#160;<span class="keyword">class </span><a class="code" href="class_sifteo_1_1_volume.html" title="A coarse-grained region of external memory.">Volume</a> {</div>
<div class="line"><a name="l00207"></a><span class="lineno">  207</span>&#160;<span class="keyword">public</span>:</div>
<div class="line"><a name="l00208"></a><span class="lineno">  208</span>&#160;    _SYSVolumeHandle sys;</div>
<div class="line"><a name="l00209"></a><span class="lineno">  209</span>&#160;</div>
<div class="line"><a name="l00211"></a><span class="lineno"><a class="code" href="class_sifteo_1_1_volume.html#a51e316c5824f5032be1ad59e90ed74ed">  211</a></span>&#160;    <span class="keyword">enum</span> <a class="code" href="class_sifteo_1_1_volume.html#a51e316c5824f5032be1ad59e90ed74ed" title="Enumeration of common volume types.">Type</a> {</div>
<div class="line"><a name="l00212"></a><span class="lineno"><a class="code" href="class_sifteo_1_1_volume.html#a51e316c5824f5032be1ad59e90ed74eda28ddc416b6e06b6b0bde07ad086a1dcc">  212</a></span>&#160;        <a class="code" href="class_sifteo_1_1_volume.html#a51e316c5824f5032be1ad59e90ed74eda28ddc416b6e06b6b0bde07ad086a1dcc" title="Volume type for normal games.">T_GAME</a>      = _SYS_FS_VOL_GAME,         </div>
<div class="line"><a name="l00213"></a><span class="lineno"><a class="code" href="class_sifteo_1_1_volume.html#a51e316c5824f5032be1ad59e90ed74eda72f830363f366b2867f53ec199f9b76f">  213</a></span>&#160;        <a class="code" href="class_sifteo_1_1_volume.html#a51e316c5824f5032be1ad59e90ed74eda72f830363f366b2867f53ec199f9b76f" title="Volume type for the system launcher.">T_LAUNCHER</a>  = _SYS_FS_VOL_LAUNCHER,     </div>
<div class="line"><a name="l00214"></a><span class="lineno">  214</span>&#160;    };</div>
<div class="line"><a name="l00215"></a><span class="lineno">  215</span>&#160;</div>
<div class="line"><a name="l00217"></a><span class="lineno"><a class="code" href="class_sifteo_1_1_volume.html#a3d096f04faed26fdd7b85095b5c7d0d2">  217</a></span>&#160;    <a class="code" href="class_sifteo_1_1_volume.html#a3d096f04faed26fdd7b85095b5c7d0d2" title="Default constructor, leaves the Volume with an invalid value of zero.">Volume</a>() : sys(0) {}</div>
<div class="line"><a name="l00218"></a><span class="lineno">  218</span>&#160;</div>
<div class="line"><a name="l00220"></a><span class="lineno"><a class="code" href="class_sifteo_1_1_volume.html#ac43458f2bdd13e842d80903a63b2c72b">  220</a></span>&#160;    <a class="code" href="class_sifteo_1_1_volume.html#ac43458f2bdd13e842d80903a63b2c72b" title="Initialize from a system object.">Volume</a>(_SYSVolumeHandle vh) : sys(vh) {}</div>
<div class="line"><a name="l00221"></a><span class="lineno">  221</span>&#160;</div>
<div class="line"><a name="l00223"></a><span class="lineno"><a class="code" href="class_sifteo_1_1_volume.html#a35c5a031471bffc9629799d42f2f3ca0">  223</a></span>&#160;    <span class="keyword">operator</span> <span class="keyword">const</span> _SYSVolumeHandle ()<span class="keyword"> const </span>{ <span class="keywordflow">return</span> sys; }</div>
<div class="line"><a name="l00224"></a><span class="lineno">  224</span>&#160;</div>
<div class="line"><a name="l00230"></a><span class="lineno">  230</span>&#160;    <span class="keyword">template</span> &lt;<span class="keywordtype">unsigned</span> T&gt;</div>
<div class="line"><a name="l00231"></a><span class="lineno"><a class="code" href="class_sifteo_1_1_volume.html#abbb04f118cdb4bf99ee83857e42478b5">  231</a></span>&#160;    <span class="keyword">static</span> <span class="keywordtype">void</span> <a class="code" href="class_sifteo_1_1_volume.html#abbb04f118cdb4bf99ee83857e42478b5" title="List all volumes of the specified type.">list</a>(<span class="keywordtype">unsigned</span> volType, <a class="code" href="class_sifteo_1_1_array.html" title="A statically sized array.">Array&lt;Volume, T&gt;</a> &amp;volumes)</div>
<div class="line"><a name="l00232"></a><span class="lineno">  232</span>&#160;    {</div>
<div class="line"><a name="l00233"></a><span class="lineno">  233</span>&#160;        volumes.<a class="code" href="class_sifteo_1_1_array.html#a9785d4195c6d0446b36244e8cabbaf08" title="Change the number of elements currently in the array.">setCount</a>(_SYS_fs_listVolumes(volType, &amp;volumes.<a class="code" href="class_sifteo_1_1_array.html#a37260ff155191f1f3ece313a74f2cd97" title="Return an iterator pointing to the first slot in the array.">begin</a>()-&gt;sys,</div>
<div class="line"><a name="l00234"></a><span class="lineno">  234</span>&#160;            volumes.<a class="code" href="class_sifteo_1_1_array.html#a31a7c9936677db7ff34df219e1aa328f" title="Retrieve the capacity of this array, always constant at compile-time.">capacity</a>()));</div>
<div class="line"><a name="l00235"></a><span class="lineno">  235</span>&#160;    }</div>
<div class="line"><a name="l00236"></a><span class="lineno">  236</span>&#160;</div>
<div class="line"><a name="l00257"></a><span class="lineno"><a class="code" href="class_sifteo_1_1_volume.html#a7ead230973e9c9c1a648221c4370fa7d">  257</a></span>&#160;    <span class="keywordtype">void</span> <a class="code" href="class_sifteo_1_1_volume.html#a7ead230973e9c9c1a648221c4370fa7d" title="Transfer control to a new program.">exec</a>()<span class="keyword"> const </span>{</div>
<div class="line"><a name="l00258"></a><span class="lineno">  258</span>&#160;        _SYS_elf_exec(sys);</div>
<div class="line"><a name="l00259"></a><span class="lineno">  259</span>&#160;    }</div>
<div class="line"><a name="l00260"></a><span class="lineno">  260</span>&#160;</div>
<div class="line"><a name="l00268"></a><span class="lineno"><a class="code" href="class_sifteo_1_1_volume.html#a6ee1e9d602e936bb56137e85a93c64a4">  268</a></span>&#160;    <span class="keyword">static</span> <a class="code" href="class_sifteo_1_1_volume.html" title="A coarse-grained region of external memory.">Volume</a> <a class="code" href="class_sifteo_1_1_volume.html#a6ee1e9d602e936bb56137e85a93c64a4" title="Return the Volume corresponding to the currently running program.">running</a>() {</div>
<div class="line"><a name="l00269"></a><span class="lineno">  269</span>&#160;        <span class="keywordflow">return</span> (_SYSVolumeHandle) _SYS_fs_runningVolume();</div>
<div class="line"><a name="l00270"></a><span class="lineno">  270</span>&#160;    }</div>
<div class="line"><a name="l00271"></a><span class="lineno">  271</span>&#160;</div>
<div class="line"><a name="l00283"></a><span class="lineno"><a class="code" href="class_sifteo_1_1_volume.html#a9ccabba03051680ccf2019f78c1aff16">  283</a></span>&#160;    <span class="keyword">static</span> <a class="code" href="class_sifteo_1_1_volume.html" title="A coarse-grained region of external memory.">Volume</a> <a class="code" href="class_sifteo_1_1_volume.html#a9ccabba03051680ccf2019f78c1aff16" title="Return the Volume corresponding to the previously running program.">previous</a>() {</div>
<div class="line"><a name="l00284"></a><span class="lineno">  284</span>&#160;        <span class="keywordflow">return</span> (_SYSVolumeHandle) _SYS_fs_previousVolume();</div>
<div class="line"><a name="l00285"></a><span class="lineno">  285</span>&#160;    }</div>
<div class="line"><a name="l00286"></a><span class="lineno">  286</span>&#160;</div>
<div class="line"><a name="l00288"></a><span class="lineno"><a class="code" href="class_sifteo_1_1_volume.html#abcb69c6daf611e2ba2f8cc76120d49a7">  288</a></span>&#160;    <span class="keywordtype">bool</span> <a class="code" href="class_sifteo_1_1_volume.html#abcb69c6daf611e2ba2f8cc76120d49a7" title="Equality comparison operator.">operator== </a>(_SYSVolumeHandle other)<span class="keyword"> const </span>{</div>
<div class="line"><a name="l00289"></a><span class="lineno">  289</span>&#160;        <span class="keywordflow">return</span> sys == other;</div>
<div class="line"><a name="l00290"></a><span class="lineno">  290</span>&#160;    }</div>
<div class="line"><a name="l00291"></a><span class="lineno">  291</span>&#160;</div>
<div class="line"><a name="l00293"></a><span class="lineno"><a class="code" href="class_sifteo_1_1_volume.html#a3ec7c16798d9a55ac23165655defe1fd">  293</a></span>&#160;    <span class="keywordtype">bool</span> <a class="code" href="class_sifteo_1_1_volume.html#a3ec7c16798d9a55ac23165655defe1fd" title="Inequality comparison operator.">operator!= </a>(_SYSVolumeHandle other)<span class="keyword"> const </span>{</div>
<div class="line"><a name="l00294"></a><span class="lineno">  294</span>&#160;        <span class="keywordflow">return</span> sys != other;</div>
<div class="line"><a name="l00295"></a><span class="lineno">  295</span>&#160;    }</div>
<div class="line"><a name="l00296"></a><span class="lineno">  296</span>&#160;};</div>
<div class="line"><a name="l00297"></a><span class="lineno">  297</span>&#160;</div>
<div class="line"><a name="l00298"></a><span class="lineno">  298</span>&#160;</div>
<div class="line"><a name="l00316"></a><span class="lineno"><a class="code" href="class_sifteo_1_1_mapped_volume.html">  316</a></span>&#160;<span class="keyword">class </span><a class="code" href="class_sifteo_1_1_mapped_volume.html" title="A Volume that has been mapped into the secondary flash memory region.">MappedVolume</a> {</div>
<div class="line"><a name="l00317"></a><span class="lineno">  317</span>&#160;    <a class="code" href="class_sifteo_1_1_volume.html" title="A coarse-grained region of external memory.">Volume</a> vol;</div>
<div class="line"><a name="l00318"></a><span class="lineno">  318</span>&#160;    uint32_t offset;</div>
<div class="line"><a name="l00319"></a><span class="lineno">  319</span>&#160;</div>
<div class="line"><a name="l00320"></a><span class="lineno">  320</span>&#160;    <span class="comment">/*</span></div>
<div class="line"><a name="l00321"></a><span class="lineno">  321</span>&#160;<span class="comment">     * On debug builds, this ensures that only one MappedVolume exists</span></div>
<div class="line"><a name="l00322"></a><span class="lineno">  322</span>&#160;<span class="comment">     * at a time. On release builds, this has no effect and the static</span></div>
<div class="line"><a name="l00323"></a><span class="lineno">  323</span>&#160;<span class="comment">     * variable optimizes out.</span></div>
<div class="line"><a name="l00324"></a><span class="lineno">  324</span>&#160;<span class="comment">     */</span></div>
<div class="line"><a name="l00325"></a><span class="lineno">  325</span>&#160;    <span class="keywordtype">void</span> debugInstanceCounter(<span class="keywordtype">int</span> delta) {</div>
<div class="line"><a name="l00326"></a><span class="lineno">  326</span>&#160;        <a class="code" href="group__macros.html#gab11c3e92066a46e1e434390342dc6dc4" title="Mark a chunk of code as debug-only.">DEBUG_ONLY</a>({</div>
<div class="line"><a name="l00327"></a><span class="lineno">  327</span>&#160;            <span class="keyword">static</span> <span class="keywordtype">int</span> counter = 0;</div>
<div class="line"><a name="l00328"></a><span class="lineno">  328</span>&#160;            counter += delta;</div>
<div class="line"><a name="l00329"></a><span class="lineno">  329</span>&#160;            <a class="code" href="group__macros.html#ga8a15779356736a0900a162442b1cda53" title="Runtime debug assertion.">ASSERT</a>(counter &gt;= 0);</div>
<div class="line"><a name="l00330"></a><span class="lineno">  330</span>&#160;            <a class="code" href="group__macros.html#ga8a15779356736a0900a162442b1cda53" title="Runtime debug assertion.">ASSERT</a>(counter &lt;= 1);</div>
<div class="line"><a name="l00331"></a><span class="lineno">  331</span>&#160;        });</div>
<div class="line"><a name="l00332"></a><span class="lineno">  332</span>&#160;    }</div>
<div class="line"><a name="l00333"></a><span class="lineno">  333</span>&#160;</div>
<div class="line"><a name="l00334"></a><span class="lineno">  334</span>&#160;<span class="keyword">public</span>:</div>
<div class="line"><a name="l00335"></a><span class="lineno">  335</span>&#160;    <span class="keyword">typedef</span> _SYSUUID UUID;</div>
<div class="line"><a name="l00336"></a><span class="lineno">  336</span>&#160;    <span class="keyword">typedef</span> _SYSMetadataCubeRange CubeRange;</div>
<div class="line"><a name="l00337"></a><span class="lineno">  337</span>&#160;</div>
<div class="line"><a name="l00338"></a><span class="lineno">  338</span>&#160;    <span class="keyword">static</span> <span class="keyword">const</span> <span class="keywordtype">unsigned</span> MAX_BOOTSTRAP_GROUPS = _SYS_MAX_METADATA_ITEM_BYTES / <span class="keyword">sizeof</span>(_SYSMetadataBootAsset);</div>
<div class="line"><a name="l00339"></a><span class="lineno">  339</span>&#160;</div>
<div class="line"><a name="l00341"></a><span class="lineno"><a class="code" href="class_sifteo_1_1_mapped_volume.html#aeea250067b90bc93a884b93068e10ace">  341</a></span>&#160;    <span class="keyword">typedef</span> <a class="code" href="class_sifteo_1_1_asset_configuration.html" title="An AssetConfiguration represents an arrangement of AssetGroups to load.">AssetConfiguration&lt;MAX_BOOTSTRAP_GROUPS&gt;</a> <a class="code" href="class_sifteo_1_1_mapped_volume.html#aeea250067b90bc93a884b93068e10ace" title="An AssetConfiguration large enough to hold all bootstrap groups.">BootstrapAssetConfiguration</a>;</div>
<div class="line"><a name="l00342"></a><span class="lineno">  342</span>&#160;</div>
<div class="line"><a name="l00344"></a><span class="lineno"><a class="code" href="class_sifteo_1_1_mapped_volume.html#a2e3f539e70963c3f919210a1bfc0b0ad">  344</a></span>&#160;    <span class="keyword">typedef</span> <a class="code" href="class_sifteo_1_1_array.html" title="A statically sized array.">Array&lt;AssetGroup, MAX_BOOTSTRAP_GROUPS&gt;</a> <a class="code" href="class_sifteo_1_1_mapped_volume.html#a2e3f539e70963c3f919210a1bfc0b0ad" title="An array large enough to hold all bototstrap AssetGroups.">BootstrapAssetGroups</a>;</div>
<div class="line"><a name="l00345"></a><span class="lineno">  345</span>&#160;</div>
<div class="line"><a name="l00351"></a><span class="lineno"><a class="code" href="class_sifteo_1_1_mapped_volume.html#add9790f82b30c3f4226589d3d47fae54">  351</a></span>&#160;    <a class="code" href="class_sifteo_1_1_mapped_volume.html#add9790f82b30c3f4226589d3d47fae54" title="Construct a detached MappedVolume.">MappedVolume</a>()</div>
<div class="line"><a name="l00352"></a><span class="lineno">  352</span>&#160;        : vol(0), offset(0) {</div>
<div class="line"><a name="l00353"></a><span class="lineno">  353</span>&#160;        debugInstanceCounter(1);</div>
<div class="line"><a name="l00354"></a><span class="lineno">  354</span>&#160;    }</div>
<div class="line"><a name="l00355"></a><span class="lineno">  355</span>&#160;</div>
<div class="line"><a name="l00362"></a><span class="lineno"><a class="code" href="class_sifteo_1_1_mapped_volume.html#a30d71f4ac5f9e4e5cb7e3a7fb465ccbc">  362</a></span>&#160;    <span class="keyword">explicit</span> <a class="code" href="class_sifteo_1_1_mapped_volume.html#a30d71f4ac5f9e4e5cb7e3a7fb465ccbc" title="Map a view of the provided Volume.">MappedVolume</a>(<a class="code" href="class_sifteo_1_1_volume.html" title="A coarse-grained region of external memory.">Volume</a> vol) {</div>
<div class="line"><a name="l00363"></a><span class="lineno">  363</span>&#160;        debugInstanceCounter(1);</div>
<div class="line"><a name="l00364"></a><span class="lineno">  364</span>&#160;        <a class="code" href="class_sifteo_1_1_mapped_volume.html#a36b85238813ba12465f54ee253a6c0fc" title="Attach this MappedVolume to a new volume.">attach</a>(vol);</div>
<div class="line"><a name="l00365"></a><span class="lineno">  365</span>&#160;    }</div>
<div class="line"><a name="l00366"></a><span class="lineno">  366</span>&#160;</div>
<div class="line"><a name="l00367"></a><span class="lineno">  367</span>&#160;    ~<a class="code" href="class_sifteo_1_1_mapped_volume.html" title="A Volume that has been mapped into the secondary flash memory region.">MappedVolume</a>()</div>
<div class="line"><a name="l00368"></a><span class="lineno">  368</span>&#160;    {</div>
<div class="line"><a name="l00369"></a><span class="lineno">  369</span>&#160;        debugInstanceCounter(-1);</div>
<div class="line"><a name="l00370"></a><span class="lineno">  370</span>&#160;</div>
<div class="line"><a name="l00371"></a><span class="lineno">  371</span>&#160;        <span class="comment">// Reclaim a little bit of memory by unmapping</span></div>
<div class="line"><a name="l00372"></a><span class="lineno">  372</span>&#160;        _SYS_elf_map(0);</div>
<div class="line"><a name="l00373"></a><span class="lineno">  373</span>&#160;    }</div>
<div class="line"><a name="l00374"></a><span class="lineno">  374</span>&#160;</div>
<div class="line"><a name="l00381"></a><span class="lineno"><a class="code" href="class_sifteo_1_1_mapped_volume.html#a36b85238813ba12465f54ee253a6c0fc">  381</a></span>&#160;    <span class="keywordtype">void</span> <a class="code" href="class_sifteo_1_1_mapped_volume.html#a36b85238813ba12465f54ee253a6c0fc" title="Attach this MappedVolume to a new volume.">attach</a>(<a class="code" href="class_sifteo_1_1_volume.html" title="A coarse-grained region of external memory.">Volume</a> vol)</div>
<div class="line"><a name="l00382"></a><span class="lineno">  382</span>&#160;    {</div>
<div class="line"><a name="l00383"></a><span class="lineno">  383</span>&#160;        <span class="keywordflow">if</span> (this-&gt;vol != vol) {</div>
<div class="line"><a name="l00384"></a><span class="lineno">  384</span>&#160;            this-&gt;vol = vol;</div>
<div class="line"><a name="l00385"></a><span class="lineno">  385</span>&#160;            offset = _SYS_elf_map(vol);</div>
<div class="line"><a name="l00386"></a><span class="lineno">  386</span>&#160;        }</div>
<div class="line"><a name="l00387"></a><span class="lineno">  387</span>&#160;    }</div>
<div class="line"><a name="l00388"></a><span class="lineno">  388</span>&#160;</div>
<div class="line"><a name="l00390"></a><span class="lineno"><a class="code" href="class_sifteo_1_1_mapped_volume.html#a6fc06a948bf8e50dc3247146c8f12003">  390</a></span>&#160;    <a class="code" href="class_sifteo_1_1_volume.html" title="A coarse-grained region of external memory.">Volume</a> <a class="code" href="class_sifteo_1_1_mapped_volume.html#a6fc06a948bf8e50dc3247146c8f12003" title="Returns the Volume associated with this mapping.">volume</a>()<span class="keyword"> const </span>{</div>
<div class="line"><a name="l00391"></a><span class="lineno">  391</span>&#160;        <span class="keywordflow">return</span> vol;</div>
<div class="line"><a name="l00392"></a><span class="lineno">  392</span>&#160;    }</div>
<div class="line"><a name="l00393"></a><span class="lineno">  393</span>&#160;</div>
<div class="line"><a name="l00408"></a><span class="lineno"><a class="code" href="class_sifteo_1_1_mapped_volume.html#aa996a30a54f8ad245c0299c00a1e2152">  408</a></span>&#160;    <span class="keywordtype">void</span> *<a class="code" href="class_sifteo_1_1_mapped_volume.html#aa996a30a54f8ad245c0299c00a1e2152" title="Look up a metadata value from the mapped Volume.">metadata</a>(<span class="keywordtype">unsigned</span> key, <span class="keywordtype">unsigned</span> minSize, <span class="keywordtype">unsigned</span> *actualSize)<span class="keyword"> const </span>{</div>
<div class="line"><a name="l00409"></a><span class="lineno">  409</span>&#160;        <span class="keywordflow">return</span> _SYS_elf_metadata(vol, key, minSize, actualSize);</div>
<div class="line"><a name="l00410"></a><span class="lineno">  410</span>&#160;    }</div>
<div class="line"><a name="l00411"></a><span class="lineno">  411</span>&#160;</div>
<div class="line"><a name="l00427"></a><span class="lineno">  427</span>&#160;    <span class="keyword">template</span> &lt;<span class="keyword">typename</span> T&gt;</div>
<div class="line"><a name="l00428"></a><span class="lineno"><a class="code" href="class_sifteo_1_1_mapped_volume.html#af5cd63cd63e7887ccb64457010ff5445">  428</a></span>&#160;    <span class="keyword">const</span> T* <a class="code" href="class_sifteo_1_1_mapped_volume.html#af5cd63cd63e7887ccb64457010ff5445" title="Look up a metadata value from the mapped Volume. The result is cast to a constant pointer of the indi...">metadata</a>(<span class="keywordtype">unsigned</span> key, <span class="keywordtype">unsigned</span> *actualSize = <a class="code" href="group__macros.html#ga070d2ce7b6bb7e5c05602aa8c308d0c4">NULL</a>)<span class="keyword"> const </span>{</div>
<div class="line"><a name="l00429"></a><span class="lineno">  429</span>&#160;        <span class="keywordflow">return</span> <span class="keyword">reinterpret_cast&lt;</span><span class="keyword">const </span>T*<span class="keyword">&gt;</span>(<a class="code" href="class_sifteo_1_1_mapped_volume.html#aa996a30a54f8ad245c0299c00a1e2152" title="Look up a metadata value from the mapped Volume.">metadata</a>(key, <span class="keyword">sizeof</span>(T), actualSize));</div>
<div class="line"><a name="l00430"></a><span class="lineno">  430</span>&#160;    }</div>
<div class="line"><a name="l00431"></a><span class="lineno">  431</span>&#160;</div>
<div class="line"><a name="l00440"></a><span class="lineno">  440</span>&#160;    <span class="keyword">template</span> &lt;<span class="keyword">typename</span> T&gt;</div>
<div class="line"><a name="l00441"></a><span class="lineno"><a class="code" href="class_sifteo_1_1_mapped_volume.html#a2dcb7daa371a7237a938105acb11bd6c">  441</a></span>&#160;    T* <a class="code" href="class_sifteo_1_1_mapped_volume.html#a2dcb7daa371a7237a938105acb11bd6c" title="Translate a virtual address in this ELF volume&#39;s read-only data segment, into a virtual address in th...">translate</a>(T* va)<span class="keyword"> const </span>{</div>
<div class="line"><a name="l00442"></a><span class="lineno">  442</span>&#160;        <span class="keywordflow">return</span> <span class="keyword">reinterpret_cast&lt;</span>T*<span class="keyword">&gt;</span>(<a class="code" href="class_sifteo_1_1_mapped_volume.html#a2dcb7daa371a7237a938105acb11bd6c" title="Translate a virtual address in this ELF volume&#39;s read-only data segment, into a virtual address in th...">translate</a>(reinterpret_cast&lt;uint32_t&gt;(va)));</div>
<div class="line"><a name="l00443"></a><span class="lineno">  443</span>&#160;    }</div>
<div class="line"><a name="l00444"></a><span class="lineno">  444</span>&#160;</div>
<div class="line"><a name="l00450"></a><span class="lineno"><a class="code" href="class_sifteo_1_1_mapped_volume.html#a095171a6943c0aeba85d4b654f8f8934">  450</a></span>&#160;    uint32_t <a class="code" href="class_sifteo_1_1_mapped_volume.html#a095171a6943c0aeba85d4b654f8f8934" title="A variant of translate() for pointers that have already been cast to uint32_t, such as pointers that ...">translate</a>(uint32_t va)<span class="keyword"> const </span>{</div>
<div class="line"><a name="l00451"></a><span class="lineno">  451</span>&#160;        <span class="keywordflow">return</span> va + offset;</div>
<div class="line"><a name="l00452"></a><span class="lineno">  452</span>&#160;    }</div>
<div class="line"><a name="l00453"></a><span class="lineno">  453</span>&#160;</div>
<div class="line"><a name="l00460"></a><span class="lineno"><a class="code" href="class_sifteo_1_1_mapped_volume.html#a9b9d30b6fdd1f0d2a8f3264fec7de048">  460</a></span>&#160;    <span class="keyword">const</span> <span class="keywordtype">char</span> *<a class="code" href="class_sifteo_1_1_mapped_volume.html#a9b9d30b6fdd1f0d2a8f3264fec7de048" title="Retrieve a mapped, NUL-terminated string with the volume&#39;s title.">title</a>(<span class="keyword">const</span> <span class="keywordtype">char</span> *placeholder = <span class="stringliteral">&quot;(untitled)&quot;</span>)<span class="keyword"> const </span>{</div>
<div class="line"><a name="l00461"></a><span class="lineno">  461</span>&#160;        <span class="keyword">const</span> <span class="keywordtype">char</span> *p = metadata&lt;char&gt;(_SYS_METADATA_TITLE_STR);</div>
<div class="line"><a name="l00462"></a><span class="lineno">  462</span>&#160;        <span class="keywordflow">return</span> p ? p : placeholder;</div>
<div class="line"><a name="l00463"></a><span class="lineno">  463</span>&#160;    }</div>
<div class="line"><a name="l00464"></a><span class="lineno">  464</span>&#160;</div>
<div class="line"><a name="l00471"></a><span class="lineno"><a class="code" href="class_sifteo_1_1_mapped_volume.html#abd2ea259e09668217ed2c280ff3c980b">  471</a></span>&#160;    <span class="keyword">const</span> <span class="keywordtype">char</span> *<a class="code" href="class_sifteo_1_1_mapped_volume.html#abd2ea259e09668217ed2c280ff3c980b" title="Retrieve a mapped, NUL-terminated string with the volume&#39;s package string.">package</a>(<span class="keyword">const</span> <span class="keywordtype">char</span> *placeholder = <span class="stringliteral">&quot;(none)&quot;</span>)<span class="keyword"> const </span>{</div>
<div class="line"><a name="l00472"></a><span class="lineno">  472</span>&#160;        <span class="keyword">const</span> <span class="keywordtype">char</span> *p = metadata&lt;char&gt;(_SYS_METADATA_PACKAGE_STR);</div>
<div class="line"><a name="l00473"></a><span class="lineno">  473</span>&#160;        <span class="keywordflow">return</span> p ? p : placeholder;</div>
<div class="line"><a name="l00474"></a><span class="lineno">  474</span>&#160;    }</div>
<div class="line"><a name="l00475"></a><span class="lineno">  475</span>&#160;</div>
<div class="line"><a name="l00482"></a><span class="lineno"><a class="code" href="class_sifteo_1_1_mapped_volume.html#a22ff8098d67194b5cf768ff492047405">  482</a></span>&#160;    <span class="keyword">const</span> <span class="keywordtype">char</span> *<a class="code" href="class_sifteo_1_1_mapped_volume.html#a22ff8098d67194b5cf768ff492047405" title="Retrieve a mapped, NUL-terminated string with the volume&#39;s version string.">version</a>(<span class="keyword">const</span> <span class="keywordtype">char</span> *placeholder = <span class="stringliteral">&quot;(none)&quot;</span>)<span class="keyword"> const </span>{</div>
<div class="line"><a name="l00483"></a><span class="lineno">  483</span>&#160;        <span class="keyword">const</span> <span class="keywordtype">char</span> *p = metadata&lt;char&gt;(_SYS_METADATA_VERSION_STR);</div>
<div class="line"><a name="l00484"></a><span class="lineno">  484</span>&#160;        <span class="keywordflow">return</span> p ? p : placeholder;</div>
<div class="line"><a name="l00485"></a><span class="lineno">  485</span>&#160;    }</div>
<div class="line"><a name="l00486"></a><span class="lineno">  486</span>&#160;</div>
<div class="line"><a name="l00492"></a><span class="lineno"><a class="code" href="class_sifteo_1_1_mapped_volume.html#a900fb37198d6a7d3b7248b606ff7ae3f">  492</a></span>&#160;    <span class="keyword">const</span> UUID *<a class="code" href="class_sifteo_1_1_mapped_volume.html#a900fb37198d6a7d3b7248b606ff7ae3f" title="Retrieve the volume&#39;s UUID.">uuid</a>()<span class="keyword"> const </span>{</div>
<div class="line"><a name="l00493"></a><span class="lineno">  493</span>&#160;        <span class="keyword">const</span> UUID *p = metadata&lt;UUID&gt;(_SYS_METADATA_UUID);</div>
<div class="line"><a name="l00494"></a><span class="lineno">  494</span>&#160;        <span class="keyword">static</span> UUID zero;</div>
<div class="line"><a name="l00495"></a><span class="lineno">  495</span>&#160;        <span class="keywordflow">return</span> p ? p : &amp;zero;</div>
<div class="line"><a name="l00496"></a><span class="lineno">  496</span>&#160;    }</div>
<div class="line"><a name="l00497"></a><span class="lineno">  497</span>&#160;</div>
<div class="line"><a name="l00508"></a><span class="lineno"><a class="code" href="class_sifteo_1_1_mapped_volume.html#aa677adfdd74bd1d3ca452e8fa45ccf49">  508</a></span>&#160;    <span class="keywordtype">void</span> <a class="code" href="class_sifteo_1_1_mapped_volume.html#a2dcb7daa371a7237a938105acb11bd6c" title="Translate a virtual address in this ELF volume&#39;s read-only data segment, into a virtual address in th...">translate</a>(<span class="keyword">const</span> _SYSMetadataBootAsset &amp;meta, <a class="code" href="struct_sifteo_1_1_asset_group.html" title="A bundle of compressed tile data, for use by AssetImages.">AssetGroup</a> &amp;group)</div>
<div class="line"><a name="l00509"></a><span class="lineno">  509</span>&#160;    {</div>
<div class="line"><a name="l00510"></a><span class="lineno">  510</span>&#160;        <a class="code" href="group__memory.html#ga20938d45e7d2889376bd3151c5a1ce44" title="Write &#39;n&#39; zero bytes to memory.">bzero</a>(group);</div>
<div class="line"><a name="l00511"></a><span class="lineno">  511</span>&#160;        group.sys.pHdr = <a class="code" href="class_sifteo_1_1_mapped_volume.html#a2dcb7daa371a7237a938105acb11bd6c" title="Translate a virtual address in this ELF volume&#39;s read-only data segment, into a virtual address in th...">translate</a>(meta.pHdr);</div>
<div class="line"><a name="l00512"></a><span class="lineno">  512</span>&#160;    }</div>
<div class="line"><a name="l00513"></a><span class="lineno">  513</span>&#160;</div>
<div class="line"><a name="l00531"></a><span class="lineno"><a class="code" href="class_sifteo_1_1_mapped_volume.html#a7f350dace9278fa51234339e7478c866">  531</a></span>&#160;    <span class="keywordtype">void</span> <a class="code" href="class_sifteo_1_1_mapped_volume.html#a2dcb7daa371a7237a938105acb11bd6c" title="Translate a virtual address in this ELF volume&#39;s read-only data segment, into a virtual address in th...">translate</a>(<span class="keyword">const</span> _SYSMetadataImage *meta, <a class="code" href="struct_sifteo_1_1_asset_image.html" title="Any kind of asset image, as defined in your stir script.">AssetImage</a> &amp;image, <a class="code" href="struct_sifteo_1_1_asset_group.html" title="A bundle of compressed tile data, for use by AssetImages.">AssetGroup</a> &amp;group)</div>
<div class="line"><a name="l00532"></a><span class="lineno">  532</span>&#160;    {</div>
<div class="line"><a name="l00533"></a><span class="lineno">  533</span>&#160;        <a class="code" href="group__memory.html#ga20938d45e7d2889376bd3151c5a1ce44" title="Write &#39;n&#39; zero bytes to memory.">bzero</a>(group);</div>
<div class="line"><a name="l00534"></a><span class="lineno">  534</span>&#160;        group.sys.pHdr = <a class="code" href="class_sifteo_1_1_mapped_volume.html#a2dcb7daa371a7237a938105acb11bd6c" title="Translate a virtual address in this ELF volume&#39;s read-only data segment, into a virtual address in th...">translate</a>(meta-&gt;groupHdr);</div>
<div class="line"><a name="l00535"></a><span class="lineno">  535</span>&#160;</div>
<div class="line"><a name="l00536"></a><span class="lineno">  536</span>&#160;        <a class="code" href="group__memory.html#ga20938d45e7d2889376bd3151c5a1ce44" title="Write &#39;n&#39; zero bytes to memory.">bzero</a>(image);</div>
<div class="line"><a name="l00537"></a><span class="lineno">  537</span>&#160;        image.sys.pAssetGroup = <span class="keyword">reinterpret_cast&lt;</span>uint32_t<span class="keyword">&gt;</span>(&amp;group);</div>
<div class="line"><a name="l00538"></a><span class="lineno">  538</span>&#160;        image.sys.width = meta-&gt;width;</div>
<div class="line"><a name="l00539"></a><span class="lineno">  539</span>&#160;        image.sys.height = meta-&gt;height;</div>
<div class="line"><a name="l00540"></a><span class="lineno">  540</span>&#160;        image.sys.frames = meta-&gt;frames;</div>
<div class="line"><a name="l00541"></a><span class="lineno">  541</span>&#160;        image.sys.format = meta-&gt;format;</div>
<div class="line"><a name="l00542"></a><span class="lineno">  542</span>&#160;        image.sys.pData = <a class="code" href="class_sifteo_1_1_mapped_volume.html#a2dcb7daa371a7237a938105acb11bd6c" title="Translate a virtual address in this ELF volume&#39;s read-only data segment, into a virtual address in th...">translate</a>(meta-&gt;pData);</div>
<div class="line"><a name="l00543"></a><span class="lineno">  543</span>&#160;    }</div>
<div class="line"><a name="l00544"></a><span class="lineno">  544</span>&#160;</div>
<div class="line"><a name="l00549"></a><span class="lineno"><a class="code" href="class_sifteo_1_1_mapped_volume.html#a2777e48c491450af1164acd47da5a6a6">  549</a></span>&#160;    <span class="keywordtype">void</span> <a class="code" href="class_sifteo_1_1_mapped_volume.html#a2777e48c491450af1164acd47da5a6a6" title="Get the bootstrap assets for this Volume, returning the result in the provided BootstrapAssetConfigur...">getBootstrap</a>(<a class="code" href="class_sifteo_1_1_array.html" title="A statically sized array.">BootstrapAssetGroups</a> &amp;groups, <a class="code" href="class_sifteo_1_1_asset_configuration.html" title="An AssetConfiguration represents an arrangement of AssetGroups to load.">BootstrapAssetConfiguration</a> &amp;config)</div>
<div class="line"><a name="l00550"></a><span class="lineno">  550</span>&#160;    {</div>
<div class="line"><a name="l00551"></a><span class="lineno">  551</span>&#160;        uint32_t actual;</div>
<div class="line"><a name="l00552"></a><span class="lineno">  552</span>&#160;        <span class="keyword">auto</span> <a class="code" href="group__math.html#gab18c9af04a4a3a4a3c63656e40ab74ed" title="Create a Vector2, from a set of (x,y) coordinates.">vec</a> = metadata&lt;_SYSMetadataBootAsset&gt;(_SYS_METADATA_BOOT_ASSET, &amp;actual);</div>
<div class="line"><a name="l00553"></a><span class="lineno">  553</span>&#160;        <span class="keywordflow">if</span> (!<a class="code" href="group__math.html#gab18c9af04a4a3a4a3c63656e40ab74ed" title="Create a Vector2, from a set of (x,y) coordinates.">vec</a>)</div>
<div class="line"><a name="l00554"></a><span class="lineno">  554</span>&#160;            <span class="keywordflow">return</span>;</div>
<div class="line"><a name="l00555"></a><span class="lineno">  555</span>&#160;</div>
<div class="line"><a name="l00556"></a><span class="lineno">  556</span>&#160;        <span class="keywordtype">unsigned</span> count = actual / <span class="keyword">sizeof</span> *<a class="code" href="group__math.html#gab18c9af04a4a3a4a3c63656e40ab74ed" title="Create a Vector2, from a set of (x,y) coordinates.">vec</a>;</div>
<div class="line"><a name="l00557"></a><span class="lineno">  557</span>&#160;        <span class="keywordflow">for</span> (<span class="keywordtype">unsigned</span> i = 0; i != count; ++i) {</div>
<div class="line"><a name="l00558"></a><span class="lineno">  558</span>&#160;</div>
<div class="line"><a name="l00559"></a><span class="lineno">  559</span>&#160;            <a class="code" href="struct_sifteo_1_1_asset_group.html" title="A bundle of compressed tile data, for use by AssetImages.">AssetGroup</a> &amp;group = groups.<a class="code" href="class_sifteo_1_1_array.html#a7d0630dc64e8561beca6e1370238e557" title="Synonym for push_back()">append</a>();</div>
<div class="line"><a name="l00560"></a><span class="lineno">  560</span>&#160;            <a class="code" href="class_sifteo_1_1_mapped_volume.html#a2dcb7daa371a7237a938105acb11bd6c" title="Translate a virtual address in this ELF volume&#39;s read-only data segment, into a virtual address in th...">translate</a>(<a class="code" href="group__math.html#gab18c9af04a4a3a4a3c63656e40ab74ed" title="Create a Vector2, from a set of (x,y) coordinates.">vec</a>[i], group);</div>
<div class="line"><a name="l00561"></a><span class="lineno">  561</span>&#160;</div>
<div class="line"><a name="l00562"></a><span class="lineno">  562</span>&#160;            config.<a class="code" href="class_sifteo_1_1_asset_configuration.html#aded2e668733f1d331927813244a2c264" title="Add an AssetGroup to this configuration.">append</a>(<a class="code" href="group__math.html#gab18c9af04a4a3a4a3c63656e40ab74ed" title="Create a Vector2, from a set of (x,y) coordinates.">vec</a>[i].slot, group, <a class="code" href="class_sifteo_1_1_mapped_volume.html#a6fc06a948bf8e50dc3247146c8f12003" title="Returns the Volume associated with this mapping.">volume</a>());</div>
<div class="line"><a name="l00563"></a><span class="lineno">  563</span>&#160;        }</div>
<div class="line"><a name="l00564"></a><span class="lineno">  564</span>&#160;    }</div>
<div class="line"><a name="l00565"></a><span class="lineno">  565</span>&#160;};</div>
<div class="line"><a name="l00566"></a><span class="lineno">  566</span>&#160;</div>
<div class="line"><a name="l00567"></a><span class="lineno">  567</span>&#160;</div>
<div class="line"><a name="l00579"></a><span class="lineno"><a class="code" href="class_sifteo_1_1_filesystem_info.html">  579</a></span>&#160;<span class="keyword">class </span><a class="code" href="class_sifteo_1_1_filesystem_info.html" title="Information about the composition of the filesystem.">FilesystemInfo</a></div>
<div class="line"><a name="l00580"></a><span class="lineno">  580</span>&#160;{</div>
<div class="line"><a name="l00581"></a><span class="lineno">  581</span>&#160;<span class="keyword">public</span>:</div>
<div class="line"><a name="l00582"></a><span class="lineno">  582</span>&#160;    _SYSFilesystemInfo sys;</div>
<div class="line"><a name="l00583"></a><span class="lineno">  583</span>&#160;</div>
<div class="line"><a name="l00590"></a><span class="lineno"><a class="code" href="class_sifteo_1_1_filesystem_info.html#a29bc0b107265b69a4f5b48391bc5e1d2">  590</a></span>&#160;    <span class="keywordtype">void</span> <a class="code" href="class_sifteo_1_1_filesystem_info.html#a29bc0b107265b69a4f5b48391bc5e1d2" title="Inspects the current state of the filesystem, and fills in the FilesystemInfo accordingly.">gather</a>() {</div>
<div class="line"><a name="l00591"></a><span class="lineno">  591</span>&#160;        _SYS_fs_info(&amp;sys, <span class="keyword">sizeof</span> sys);</div>
<div class="line"><a name="l00592"></a><span class="lineno">  592</span>&#160;    }</div>
<div class="line"><a name="l00593"></a><span class="lineno">  593</span>&#160;</div>
<div class="line"><a name="l00600"></a><span class="lineno"><a class="code" href="class_sifteo_1_1_filesystem_info.html#ac10c5a7431c3f0136282b19c10ae1309">  600</a></span>&#160;    uint32_t <a class="code" href="class_sifteo_1_1_filesystem_info.html#ac10c5a7431c3f0136282b19c10ae1309" title="Return the size of one allocation unit.">allocationUnitSize</a>() {</div>
<div class="line"><a name="l00601"></a><span class="lineno">  601</span>&#160;        <span class="keywordflow">return</span> sys.unitSize;</div>
<div class="line"><a name="l00602"></a><span class="lineno">  602</span>&#160;    }</div>
<div class="line"><a name="l00603"></a><span class="lineno">  603</span>&#160;</div>
<div class="line"><a name="l00605"></a><span class="lineno"><a class="code" href="class_sifteo_1_1_filesystem_info.html#af71c14dc22f2f3000c93d563ac5b56d6">  605</a></span>&#160;    uint32_t <a class="code" href="class_sifteo_1_1_filesystem_info.html#af71c14dc22f2f3000c93d563ac5b56d6" title="Free space, in allocation units.">freeUnits</a>() {</div>
<div class="line"><a name="l00606"></a><span class="lineno">  606</span>&#160;        <span class="keywordflow">return</span> sys.freeUnits;</div>
<div class="line"><a name="l00607"></a><span class="lineno">  607</span>&#160;    }</div>
<div class="line"><a name="l00608"></a><span class="lineno">  608</span>&#160;</div>
<div class="line"><a name="l00610"></a><span class="lineno"><a class="code" href="class_sifteo_1_1_filesystem_info.html#a9d7da2d8aa04f981fe7068c681b1a0b5">  610</a></span>&#160;    uint32_t <a class="code" href="class_sifteo_1_1_filesystem_info.html#a9d7da2d8aa04f981fe7068c681b1a0b5" title="Free space, in bytes.">freeBytes</a>() {</div>
<div class="line"><a name="l00611"></a><span class="lineno">  611</span>&#160;        <span class="keywordflow">return</span> sys.freeUnits * sys.unitSize;</div>
<div class="line"><a name="l00612"></a><span class="lineno">  612</span>&#160;    }</div>
<div class="line"><a name="l00613"></a><span class="lineno">  613</span>&#160;</div>
<div class="line"><a name="l00615"></a><span class="lineno"><a class="code" href="class_sifteo_1_1_filesystem_info.html#a0526e495ee56b25eb3e0ae70e4ef713e">  615</a></span>&#160;    uint32_t <a class="code" href="class_sifteo_1_1_filesystem_info.html#a0526e495ee56b25eb3e0ae70e4ef713e" title="Total space, in allocation units.">totalUnits</a>() {</div>
<div class="line"><a name="l00616"></a><span class="lineno">  616</span>&#160;        <span class="keywordflow">return</span> sys.totalUnits;</div>
<div class="line"><a name="l00617"></a><span class="lineno">  617</span>&#160;    }</div>
<div class="line"><a name="l00618"></a><span class="lineno">  618</span>&#160;</div>
<div class="line"><a name="l00620"></a><span class="lineno"><a class="code" href="class_sifteo_1_1_filesystem_info.html#ac1613fcb44c9b836d8e619740bc4de4f">  620</a></span>&#160;    uint32_t <a class="code" href="class_sifteo_1_1_filesystem_info.html#ac1613fcb44c9b836d8e619740bc4de4f" title="Total space, in bytes.">totalBytes</a>() {</div>
<div class="line"><a name="l00621"></a><span class="lineno">  621</span>&#160;        <span class="keywordflow">return</span> sys.totalUnits * sys.unitSize;</div>
<div class="line"><a name="l00622"></a><span class="lineno">  622</span>&#160;    }</div>
<div class="line"><a name="l00623"></a><span class="lineno">  623</span>&#160;</div>
<div class="line"><a name="l00631"></a><span class="lineno"><a class="code" href="class_sifteo_1_1_filesystem_info.html#affddd4a3bb0037b77dfdeb4aec6aeefa">  631</a></span>&#160;    uint32_t <a class="code" href="class_sifteo_1_1_filesystem_info.html#affddd4a3bb0037b77dfdeb4aec6aeefa">systemUnits</a>() {</div>
<div class="line"><a name="l00632"></a><span class="lineno">  632</span>&#160;        <span class="keywordflow">return</span> sys.systemUnits;</div>
<div class="line"><a name="l00633"></a><span class="lineno">  633</span>&#160;    }</div>
<div class="line"><a name="l00634"></a><span class="lineno">  634</span>&#160;</div>
<div class="line"><a name="l00636"></a><span class="lineno"><a class="code" href="class_sifteo_1_1_filesystem_info.html#a8f652847351d17f637dc169a41953d3d">  636</a></span>&#160;    uint32_t <a class="code" href="class_sifteo_1_1_filesystem_info.html#a8f652847351d17f637dc169a41953d3d" title="Space used by system data, in bytes.">systemBytes</a>() {</div>
<div class="line"><a name="l00637"></a><span class="lineno">  637</span>&#160;        <span class="keywordflow">return</span> sys.systemUnits * sys.unitSize;</div>
<div class="line"><a name="l00638"></a><span class="lineno">  638</span>&#160;    }</div>
<div class="line"><a name="l00639"></a><span class="lineno">  639</span>&#160;</div>
<div class="line"><a name="l00641"></a><span class="lineno"><a class="code" href="class_sifteo_1_1_filesystem_info.html#ae61e7feee9771038f0a9101151cd4b17">  641</a></span>&#160;    uint32_t <a class="code" href="class_sifteo_1_1_filesystem_info.html#ae61e7feee9771038f0a9101151cd4b17" title="Space used by the launcher&#39;s ELF binary, in allocation units.">launcherElfUnits</a>() {</div>
<div class="line"><a name="l00642"></a><span class="lineno">  642</span>&#160;        <span class="keywordflow">return</span> sys.launcherElfUnits;</div>
<div class="line"><a name="l00643"></a><span class="lineno">  643</span>&#160;    }</div>
<div class="line"><a name="l00644"></a><span class="lineno">  644</span>&#160;</div>
<div class="line"><a name="l00646"></a><span class="lineno"><a class="code" href="class_sifteo_1_1_filesystem_info.html#a02df0124362ed22ffac2566f56115208">  646</a></span>&#160;    uint32_t <a class="code" href="class_sifteo_1_1_filesystem_info.html#a02df0124362ed22ffac2566f56115208" title="Space used by the launcher&#39;s ELF binary, in bytes.">launcherElfBytes</a>() {</div>
<div class="line"><a name="l00647"></a><span class="lineno">  647</span>&#160;        <span class="keywordflow">return</span> sys.launcherElfUnits * sys.unitSize;</div>
<div class="line"><a name="l00648"></a><span class="lineno">  648</span>&#160;    }</div>
<div class="line"><a name="l00649"></a><span class="lineno">  649</span>&#160;</div>
<div class="line"><a name="l00651"></a><span class="lineno"><a class="code" href="class_sifteo_1_1_filesystem_info.html#ae84e01c672898d8abcfb795f107d1058">  651</a></span>&#160;    uint32_t <a class="code" href="class_sifteo_1_1_filesystem_info.html#ae84e01c672898d8abcfb795f107d1058" title="Space used by the launcher&#39;s StoredObjects, in allocation units.">launcherObjUnits</a>() {</div>
<div class="line"><a name="l00652"></a><span class="lineno">  652</span>&#160;        <span class="keywordflow">return</span> sys.launcherObjUnits;</div>
<div class="line"><a name="l00653"></a><span class="lineno">  653</span>&#160;    }</div>
<div class="line"><a name="l00654"></a><span class="lineno">  654</span>&#160;</div>
<div class="line"><a name="l00656"></a><span class="lineno"><a class="code" href="class_sifteo_1_1_filesystem_info.html#a7daecfc31664d981eac6c9f92ad1794c">  656</a></span>&#160;    uint32_t <a class="code" href="class_sifteo_1_1_filesystem_info.html#a7daecfc31664d981eac6c9f92ad1794c" title="Space used by the launcher&#39;s StoredObjects, in bytes.">launcherObjBytes</a>() {</div>
<div class="line"><a name="l00657"></a><span class="lineno">  657</span>&#160;        <span class="keywordflow">return</span> sys.launcherObjUnits * sys.unitSize;</div>
<div class="line"><a name="l00658"></a><span class="lineno">  658</span>&#160;    }</div>
<div class="line"><a name="l00659"></a><span class="lineno">  659</span>&#160;</div>
<div class="line"><a name="l00661"></a><span class="lineno"><a class="code" href="class_sifteo_1_1_filesystem_info.html#a05adf58da268369365646c9562985045">  661</a></span>&#160;    uint32_t <a class="code" href="class_sifteo_1_1_filesystem_info.html#a05adf58da268369365646c9562985045" title="Space used by all game ELF binaries, in allocation units.">gameElfUnits</a>() {</div>
<div class="line"><a name="l00662"></a><span class="lineno">  662</span>&#160;        <span class="keywordflow">return</span> sys.gameElfUnits;</div>
<div class="line"><a name="l00663"></a><span class="lineno">  663</span>&#160;    }</div>
<div class="line"><a name="l00664"></a><span class="lineno">  664</span>&#160;</div>
<div class="line"><a name="l00666"></a><span class="lineno"><a class="code" href="class_sifteo_1_1_filesystem_info.html#af38b9e206bb967dbecbe5159440ff8a3">  666</a></span>&#160;    uint32_t <a class="code" href="class_sifteo_1_1_filesystem_info.html#af38b9e206bb967dbecbe5159440ff8a3" title="Space used by all game ELF binaries, in bytes.">gameElfBytes</a>() {</div>
<div class="line"><a name="l00667"></a><span class="lineno">  667</span>&#160;        <span class="keywordflow">return</span> sys.gameElfUnits * sys.unitSize;</div>
<div class="line"><a name="l00668"></a><span class="lineno">  668</span>&#160;    }</div>
<div class="line"><a name="l00669"></a><span class="lineno">  669</span>&#160;</div>
<div class="line"><a name="l00671"></a><span class="lineno"><a class="code" href="class_sifteo_1_1_filesystem_info.html#abc6210ff1982a7695002a1eb72e32cc7">  671</a></span>&#160;    uint32_t <a class="code" href="class_sifteo_1_1_filesystem_info.html#abc6210ff1982a7695002a1eb72e32cc7" title="Space used by all game StoredObjects, in allocation units.">gameObjUnits</a>() {</div>
<div class="line"><a name="l00672"></a><span class="lineno">  672</span>&#160;        <span class="keywordflow">return</span> sys.gameObjUnits;</div>
<div class="line"><a name="l00673"></a><span class="lineno">  673</span>&#160;    }</div>
<div class="line"><a name="l00674"></a><span class="lineno">  674</span>&#160;</div>
<div class="line"><a name="l00676"></a><span class="lineno"><a class="code" href="class_sifteo_1_1_filesystem_info.html#aea02ec858d3dc07d9fc3db1451effa76">  676</a></span>&#160;    uint32_t <a class="code" href="class_sifteo_1_1_filesystem_info.html#aea02ec858d3dc07d9fc3db1451effa76" title="Space used by all game StoredObjects, in bytes.">gameObjBytes</a>() {</div>
<div class="line"><a name="l00677"></a><span class="lineno">  677</span>&#160;        <span class="keywordflow">return</span> sys.gameObjUnits * sys.unitSize;</div>
<div class="line"><a name="l00678"></a><span class="lineno">  678</span>&#160;    }</div>
<div class="line"><a name="l00679"></a><span class="lineno">  679</span>&#160;</div>
<div class="line"><a name="l00681"></a><span class="lineno"><a class="code" href="class_sifteo_1_1_filesystem_info.html#afcda0c308cf10e3bcfd6d58d606a97d2">  681</a></span>&#160;    uint32_t <a class="code" href="class_sifteo_1_1_filesystem_info.html#afcda0c308cf10e3bcfd6d58d606a97d2" title="Space used by the current volume&#39;s ELF binary, in allocation units.">selfElfUnits</a>() {</div>
<div class="line"><a name="l00682"></a><span class="lineno">  682</span>&#160;        <span class="keywordflow">return</span> sys.selfElfUnits;</div>
<div class="line"><a name="l00683"></a><span class="lineno">  683</span>&#160;    }</div>
<div class="line"><a name="l00684"></a><span class="lineno">  684</span>&#160;</div>
<div class="line"><a name="l00686"></a><span class="lineno"><a class="code" href="class_sifteo_1_1_filesystem_info.html#afbc7fa4961cb50c261bfdace1af7cb6a">  686</a></span>&#160;    uint32_t <a class="code" href="class_sifteo_1_1_filesystem_info.html#afbc7fa4961cb50c261bfdace1af7cb6a" title="Space used by the current volume&#39;s ELF binary, in bytes.">selfElfBytes</a>() {</div>
<div class="line"><a name="l00687"></a><span class="lineno">  687</span>&#160;        <span class="keywordflow">return</span> sys.selfElfUnits * sys.unitSize;</div>
<div class="line"><a name="l00688"></a><span class="lineno">  688</span>&#160;    }</div>
<div class="line"><a name="l00689"></a><span class="lineno">  689</span>&#160;</div>
<div class="line"><a name="l00691"></a><span class="lineno"><a class="code" href="class_sifteo_1_1_filesystem_info.html#ab9ec5c856dbb26215f75cfe07e68a052">  691</a></span>&#160;    uint32_t <a class="code" href="class_sifteo_1_1_filesystem_info.html#ab9ec5c856dbb26215f75cfe07e68a052" title="Space used by the current volume&#39;s StoredObjects, in allocation units.">selfObjUnits</a>() {</div>
<div class="line"><a name="l00692"></a><span class="lineno">  692</span>&#160;        <span class="keywordflow">return</span> sys.selfObjUnits;</div>
<div class="line"><a name="l00693"></a><span class="lineno">  693</span>&#160;    }</div>
<div class="line"><a name="l00694"></a><span class="lineno">  694</span>&#160;</div>
<div class="line"><a name="l00696"></a><span class="lineno"><a class="code" href="class_sifteo_1_1_filesystem_info.html#a103ea52dbcb0f6cb1737cfdab827b5d3">  696</a></span>&#160;    uint32_t <a class="code" href="class_sifteo_1_1_filesystem_info.html#a103ea52dbcb0f6cb1737cfdab827b5d3" title="Space used by the current volume&#39;s StoredObjects, in bytes.">selfObjBytes</a>() {</div>
<div class="line"><a name="l00697"></a><span class="lineno">  697</span>&#160;        <span class="keywordflow">return</span> sys.selfObjUnits * sys.unitSize;</div>
<div class="line"><a name="l00698"></a><span class="lineno">  698</span>&#160;    }</div>
<div class="line"><a name="l00699"></a><span class="lineno">  699</span>&#160;};</div>
<div class="line"><a name="l00700"></a><span class="lineno">  700</span>&#160;</div>
<div class="line"><a name="l00701"></a><span class="lineno">  701</span>&#160;</div>
<div class="line"><a name="l00706"></a><span class="lineno">  706</span>&#160;} <span class="comment">// namespace Sifteo</span></div>
</div><!-- fragment --></div><!-- contents -->
<!-- HTML footer for doxygen 1.8.3.1-->
<!-- start footer part -->
    <hr class="footer"/>
    <address class="footer">
        <p><a href="http://sifteo.com">Sifteo</a> SDK v1.0.0 <small>(see <a href="https://developers.sifteo.com/sifteosdk">all versions</a>)</small></p>
        <p>Last updated Wed Mar 27 2013, by <a href="http://www.stack.nl/~dimitri/doxygen">Doxygen</a></p>
    </address>
</body>
</html>
